database, PHSAMPLE.DBF, then you can remove PhDbase from your systemAppendix A: Removing PhDbase From Your System
directory. Please read the following notes and instructions carefully.PhDbase files. You probably also have a file called PHSAMPLE.CDX, thesimply by erasing the PhDbase files located in your FoxPro 2 directo-
This file should also be erased.If the only database that you have Quick searched is our sample
index file that we created when we Quick searched the sample database.ry. Refer to the installation section of the manual for a list of the
system, in addition to erasing the PhDbase files from your FoxPro 2If you have Quick searched any of your own databases, however, there
is one step you need to take to successfully remove PhDbase from your──────────────────────────────────────────────────────────────────────
16 Korenthal Associates, Inc.the same directory as the database file. This file is a FoxProextension of .CDX. For example, if you "Quick searched" our sample
FoxPro 2 directory, FoxPro will no longer be able to find the programdatabase, PHSAMPLE.DBF, you will find a file called PHSAMPLE.CDX in
index.TAG keyword, without the optional OF clause, in the FoxPro INDEX
Whenever you open a database with an index, FoxPro evaluates the index"structural index", which is always opened by FoxPro whenever you open
command. PhDbase creates its phonetic indexes as TAGs in a structuralits related database. Structural indexes are created by including the
called PHDBASE. If you have erased the PhDbase files from yourthat has been made "PhDbase-ready", FoxPro will look for a programwhen you add records or change your data. In the case of a databaseindex file that has the same name as the database, but with a file
expressions to ensure that it can successfully update the index filesAny database that has been prepared for a Quick search now has an
it needs to keep your PhDbase indexes up-to-date, and will display an
To complete the removal of PhDbase from your system and avoid seeing
this error message, you must delete the PhDbase index tags from the
database's structural index. For each database that has one or more
includes PHDBASE in itsOpen the database exclusively.USE <database name> EXCLUSIVEDescriptionType in the Command WindowPhDbase indexes, do the following:
─────────── ──────────────────────────
index tags on the screen.
For each index tag that DELETE TAG <tagname>Display the names of theDISPLAY STATUSerror message "File PHDBASE does not exist".
index expression.
To avoid conflicting with any non-PhDbase tags, PhDbase uses tag names
which are guaranteed to be unique. They are always ten characters
long, and always begin with the underscore character ("_").
Example:
After opening the PHSAMPLE database, typing DISPLAY STATUS in the
Command window shows the following information:
Currently Selected Database:
Select area: 1, Database in Use: C:\FOXPRO2\PHSAMPLE.DBF
Structural CDX file: C:\FOXPRO2\PHSAMPLE.CDX
Index tag: _PZ50YD2BI Key: PHDBASE(COMPANY)
Index tag: _PZ518MNJS Key: PHDBASE(LAST)
Index tag: _PZ518MRSK Key: PHDBASE(FIRST)
Index tag: STATE Key: STATE
Lock(s): <none>
In this example, the PhDbase index tags are _PZ50YD2BI, _PZ518MNJS and
_PZ518MRSK. To remove the PhDbase index tags, we would enter these
commands in the Command window:
USE C:\FOXPRO2\PHSAMPLE EXCLUSIVE
DELETE TAG _PZ50YD2BI
DELETE TAG _PZ518MNJS
DELETE TAG _PZ518MRSK
Now when you use the DISPLAY STATUS command, you should see that the
PhDbase indexes are gone. If they were the only index tags in the
structural (.CDX) index file, FoxPro has erased the structural index,
and its name no longer appears beneath the database name. This is as
it should be. You can create a new structural index at any time.
If you know how to use FoxPro's View window, you can also delete these
tags from the View window. Open the View window, select <Setup>, and
then <Modify> (the one in the box beneath "Index"). Now highlight the
first index expression that contains the word PHDBASE, press the space
bar (or click on it with the mouse) to select it, and select
<Remove/Edit>. The index name will be removed from the list of "Index
On:" expressions. Select <<OK>> (you can press Ctrl-Enter as a short-
cut), and then confirm the action by answering "Yes" to FoxPro's
"Remove <tag name> from this CDX file?" question.
Repeat this procedure for each of the remaining PhDbase index tags.
If you are using the network version of FoxPro, you will still have to
gain exclusive use of the database. Either open the database from the
Command window with USE <database name> EXCLUSIVE, or SET EXCLUSIVE
ON before activating the View window.
If you have already received the "File PHDBASE does not exist" error
message, don't worry! No damage has been done to any of your database
files. Just press the Enter key until the error message is not dis-